using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration;

namespace ConsoleApplication2.Models.Mapping
{
    public class vt_test6Map : EntityTypeConfiguration<vt_test6>
    {
        public vt_test6Map()
        {
            // Primary Key
            this.HasKey(t => t.account__);

            // Properties
            this.Property(t => t.customer__)
                .HasMaxLength(10);

            this.Property(t => t.Customer)
                .HasMaxLength(110);

            this.Property(t => t.account__)
                .IsRequired()
                .HasMaxLength(40);

            // Table & Column Mappings
            this.ToTable("vt_test6");
            this.Property(t => t.customer__).HasColumnName("customer_#");
            this.Property(t => t.Customer).HasColumnName("Customer");
            this.Property(t => t.account__).HasColumnName("account_#");
            this.Property(t => t.Cutsomer_balance_Method1).HasColumnName("Cutsomer_balance_Method1");
            this.Property(t => t.Cutsomer_balance_Method2).HasColumnName("Cutsomer_balance_Method2");
            this.Property(t => t.currency_difference).HasColumnName("currency_difference");
        }
    }
}
